import { Component, useState } from "react";
import {
  Button,
  Cell,
  Empty,
  Avatar,
  Grid,
  Image,
} from "@nutui/nutui-react-taro";
import styles from "./index.scss";
import { useModel } from "@/store";
import Taro from "@tarojs/taro";
import { Space } from "@nutui/nutui-react-taro";
// import { IconFont } from "@nutui/icons-react-taro";
export default (props) => {
  const { item } = props;
  // const list5 = Array.from(new Array(2).keys());

  return (
    <view className={styles.seconddepWarp}>
      {/* <Space direction="vertical">
        {list.map((x) => ( */}
      <view
        className={styles.seconddepTitle}
        key={item?.deptCode}
        onClick={() => {
          if (item?.deptCode) {
            Taro.navigateTo({
              url: `/pages/register/selectschedule/index?deptCode=${item?.deptCode}&deptName=${item?.deptName}`,
            });
          }
        }}
      >
        {item?.deptName}
      </view>
      {/* ))}
      </Space> */}
    </view>
  );
};
